import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:xingsu/util/use_preferences.dart';
import 'package:xingsu/widget/privacy_dialog.dart';

class TabViewModel extends GetxController {
  final PageController controller = PageController(
    initialPage: 0,
  );

  final currentIndex = 0.obs;

  List<List> tabs = [
    ["首页", "tab_home"],
    ["发行人", "tab_publisher"],
    // ["队友", "tab_team"],
    ["我的", "tab_mine"],
  ];

  @override
  void onInit() {
    super.onInit();

    if (!UserPreferences.getAgreeAgreement()) {
      Future.delayed(const Duration(seconds: 1), () {
        showPrivacyDialog();
      });
    }
  }
}
